package org.duncan.sjge.utils;

/**
 *
 * @author Duncan
 */
public class Time {
    private long mMilliseconds;
    
    public static class Milliseconds extends Time {
        public Milliseconds(final long milliseconds) {
            super(milliseconds);
        }
    }
    
    public static class Seconds extends Time {
        public Seconds(final long seconds) {
            super(seconds * 1000);
        }
    }
    
    private Time(final long milliseconds) {
        mMilliseconds = milliseconds;
    }
    
    public long asMilliseconds() {
        return mMilliseconds;
    }
    
    public long asSeconds() {
        return mMilliseconds / 1000;
    }
}
